package pl.edu.agh.ki.ewywiadowka.client.dto;

import java.util.Date;

import com.google.gwt.user.client.rpc.IsSerializable;

public class AbsenceDTO implements IsSerializable {

	//klucz obcy
	public StudentDTO student;
	public Integer id;
	public Date start;
	public Date stop;
	public Boolean excused;
	
	public AbsenceDTO() {}

	public AbsenceDTO(StudentDTO student, Integer id, Date start, Date stop,
			Boolean excused) {
		super();
		this.student = student;
		this.id = id;
		this.start = start;
		this.stop = stop;
		this.excused = excused;
	}
	
	public boolean equals(AbsenceDTO adto) {
		return student.equals(adto.student) && start.equals(adto.start) && stop.equals(adto.stop) && excused==adto.excused;
	}
	
}
